Skip to content

branch-4.0: [Feature](Iceberg) Implement publish_changes procedure for Iceberg tables #58755#58880

Closed
github-actions[bot] wants to merge 1 commit intobranch-4.0from
auto-pick-58755-branch-4.0
Closed

branch-4.0: [Feature](Iceberg) Implement publish_changes procedure for Iceberg tables #58755#58880
github-actions[bot] wants to merge 1 commit intobranch-4.0from
auto-pick-58755-branch-4.0

Conversation

@github-actions
Copy link
Contributor

@github-actions github-actions bot commented Dec 9, 2025

Cherry-picked from #58755

@github-actions github-actions bot requested a review from yiguolei as a code owner December 9, 2025 14:32
@Thearas
Copy link
Contributor

Thearas commented Dec 9, 2025

Thank you for your contribution to Apache Doris.
Don't know what should be done next? See How to process your PR.

Please clearly describe your PR:

  1. What problem was fixed (it's best to include specific error reporting information). How it was fixed.
  2. Which behaviors were modified. What was the previous behavior, what is it now, why was it modified, and what possible impacts might there be.
  3. What features were added. Why was this function added?
  4. Which code was refactored and why was this part of the code refactored?
  5. Which functions were optimized and what is the difference before and after the optimization?

@dataroaring dataroaring closed this Dec 9, 2025
@dataroaring dataroaring reopened this Dec 9, 2025
@Thearas
Copy link
Contributor

Thearas commented Dec 9, 2025

run buildall

…bles (#58755)

### What problem does this PR solve?

- **Issue Number**: part of #58199
- **Related PR**: N/A

Problem Summary:
This PR implements the `publish_changes` action for Iceberg tables. This
action serves as the "Publish" step in the Write-Audit-Publish (WAP)
pattern. The procedure locates a snapshot tagged with a specific
`wap.id` property and cherry-picks it into the current table state. This
allows users to atomically make "staged" data visible after validation.

Syntax:
```sql
EXECUTE TABLE catalog.db.table_name publish_changes("wap_id" = "batch_123");
````

Output:
Returns `previous_snapshot_id` (STRING) and `current_snapshot_id`
(STRING) indicating the state transition.

Use cases:

1.  Implement Write-Audit-Publish (WAP) workflows.
2.  Atomically publish validated data to the main branch.
3.  Manage staged snapshots based on custom WAP IDs.

Co-authored-by: Chenjunwei <chenjunwei@ChenjunweideMacBook-Pro.local>
@yiguolei yiguolei force-pushed the auto-pick-58755-branch-4.0 branch from 82afb0e to 4aa7285 Compare December 12, 2025 01:23
@yiguolei
Copy link
Contributor

run buildall

@morningman morningman closed this Jan 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants